from AnalysisService.util.Log import log
import os

test_file = '/opt/avison-young.txt'
isbool = os.path.exists(test_file)
log.i("测试环境：", isbool)

# if isbool:
#
#     AVISONY_DB_HOST = "10.100.10.197"
#     AVISONY_DB_PORT = 27017
#     AVISONY_DB_NAEM = "AvisonYoungDB"
#     AVISONY_DB_USER = "qmyiz"
#     AVISONY_DB_PWD = "qmyiz"
#
# else:
#
#     AVISONY_DB_HOST = "dds-wz9f8d5e6901a7041665-pub.mongodb.rds.aliyuncs.com"  # 外网
#     # AVISONY_DB_HOST = 'dds-wz9f8d5e6901a7041.mongodb.rds.aliyuncs.com' #内网
#     AVISONY_DB_PORT = 3717
#     AVISONY_DB_NAEM = "AvisonYoungDB"
#     AVISONY_DB_USER = "root"
#     AVISONY_DB_PWD = "Abc123456"


AVISONY_DB_HOST = "dds-wz9f1c4b7585a9441172-pub.mongodb.rds.aliyuncs.com"  # 外网
# AVISONY_DB_HOST = 'dds-wz9f8d5e6901a7041.mongodb.rds.aliyuncs.com' #内网
AVISONY_DB_PORT = 3717
AVISONY_DB_NAEM = "AnalysisDB"
AVISONY_DB_USER = "harry"
AVISONY_DB_PWD = "123456"


AVISONY_CAPTCHA_COLLECTION = 'AYCaptcha'
AVISONY_ENTRY_COLLECTION = 'AYEntry'

ALIYUN_ACCESS_KEY_ID = "LTAIENulfjBOTxpX"
ALIYUN_ACCESS_KEY_SECRET = "5mYrxHihrxh4mGVeOT3ofAz0NN48WB"

API_RESULT_KEY = 'results'

DATE_FORAMT = '%Y-%m-%d %H:%M:%S'
DAY_FORAMT = '%Y-%m-%d'
MONTH_FORAMT = '%Y-%m'
